package com.meisupic.copyright.domain.po;

import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import lombok.Data;
import org.hibernate.annotations.CreationTimestamp;
import org.hibernate.annotations.DynamicUpdate;

/**
 * @Author lanjian
 * @Date 2018/3/14 上午11:09
 */

@Data
@Entity
@Table(name = "copyright_monitor_result")
@DynamicUpdate
public class MonitorResult {

  @Id
  @GeneratedValue
  private Long id;

  @Column(name = "monitor_record_id", length = 20)
  private Long monitorRecordId;

  @Column(name = "works_image_url", length = 200)
  private String workImgUrl;

  @Column(name = "page_url", length = 200)
  private String pageUrl;

  @Column(name = "result_image_url", length = 200)
  private String resultImgUrl;

  @Column(name = "similarity", precision = 5, scale = 2)
  private BigDecimal similarity;

  @Column(name = "ingore_status", columnDefinition = "bit(1) DEFAULT b'0'",nullable = false)
  private Boolean ingoreStatus;

  @Column(name = "user_id", length = 20, nullable = false)
  private Long userId;

  @Column(name = "create_time", nullable = false)
  @CreationTimestamp()
  private Date createTime;
}
